package com.example.project.controller;

import com.example.project.entity.TcdmSecureClassifyGrade;
import com.example.project.service.TcdmSecureClassifyGradeService;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
@CrossOrigin
@RequestMapping("tcdmSecureClassifyGrade")
public class TcdmSecureClassifyGradeController {
    @Resource
    private TcdmSecureClassifyGradeService tcdmSecureClassifyGradeService;

    /**
     * 获取隐患分类
     * @return 隐患分类
     */
    @GetMapping("getClassify")
    public List<TcdmSecureClassifyGrade> getAllClassify(){
        return this.tcdmSecureClassifyGradeService.getAllClassify();
    }

    @GetMapping("getGrade")
    public  List<TcdmSecureClassifyGrade> getAllGrade(){
        return  this.tcdmSecureClassifyGradeService.getAllGrade();
    }

}
